package com.hspedu;

/**
 * @author 谷其昊
 * @version 1.0
 * @date 2022/2/14
 * @time 20:44
 */
public class CPUNum {
    public static void main(String[] args) {
        Runtime runtime = Runtime.getRuntime();
        //获取当前电脑的CPU
        int cpuNums = runtime.availableProcessors();
        System.out.println(cpuNums);

    }
}
